import 'package:json_annotation/json_annotation.dart';

part 'interest_bean.g.dart';


@JsonSerializable()
class InterestBean extends Object {

  @JsonKey(name: 'auth_rule')
  int authRule;

  @JsonKey(name: 'big_class_id')
  int bigClassId;

  @JsonKey(name: 'create_by_id')
  int createById;

  @JsonKey(name: 'create_date')
  int createDate;

  @JsonKey(name: 'description')
  String description;

  @JsonKey(name: 'group_level')
  int groupLevel;

  @JsonKey(name: 'group_logo')
  String groupLogo;

  @JsonKey(name: 'hidden')
  bool hidden;

  @JsonKey(name: 'hot')
  int hot;

  @JsonKey(name: 'id')
  int id;

  @JsonKey(name: 'identification')
  int identification;

  @JsonKey(name: 'manager1_id')
  int manager1Id;

  @JsonKey(name: 'manager2_id')
  int manager2Id;

  @JsonKey(name: 'name')
  String name;

  @JsonKey(name: 'qrcode')
  String qrcode;

  @JsonKey(name: 'slogan')
  String slogan;

  @JsonKey(name: 'user_count')
  int userCount;

  @JsonKey(name: 'recent_post')
  List<Recent_post> recentPost;

  InterestBean({this.authRule,this.bigClassId,this.createById,this.createDate,this.description,this.groupLevel,this.groupLogo,this.hidden,this.hot,this.id,this.identification,this.manager1Id,this.manager2Id,this.name,this.qrcode,this.slogan,this.userCount,this.recentPost});

  factory InterestBean.fromJson(Map<String, dynamic> srcJson) => _$InterestBeanFromJson(srcJson);

  Map<String, dynamic> toJson() => _$InterestBeanToJson(this);

}


@JsonSerializable()
class Recent_post extends Object {

  @JsonKey(name: 'id')
  int id;

  @JsonKey(name: 'name')
  String name;

  Recent_post(this.id,this.name,);

  factory Recent_post.fromJson(Map<String, dynamic> srcJson) => _$Recent_postFromJson(srcJson);

  Map<String, dynamic> toJson() => _$Recent_postToJson(this);

}


